<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%
String path = request.getContextPath();
%>
<!--  2010-10-12 忘记密码 -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title>忘记密码</title>
	<link href="<%=path %>/css/index_css.css" rel="stylesheet" type="text/css" />
	<script type="text/javascript">
	function setPass()
	{
	  	  var password1=document.getElementById("password1");
		  var password2=document.getElementById("password2");
		  if(password1.value=="")
		  {
		  	alert("输入的新密码不允许为空！");
		  	password1.focus();
		  	return false;
		  }
		  if(password1.value!=password2.value)
		  {
		  	alert("两次输入的新密码必须一致！");
		  	password1.value="";
		  	password2.value="";
		  	password1.focus();
		  	return false;
		  }
		  return true;
	}
	</script>
  </head>
  
  <body onload="try{document.getElementById('password1').focus();}catch(e){}">
    <table width="760" align="center"  border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td align="center"><img src="<%=path %>/images/workroom_getback.gif"></td>
      </tr>
      <tr>
        <td>&nbsp;</td>
      </tr>
      <tr>
        <td align="center">
          <c:choose>
            <c:when test="${requestScope.result eq 'right'}">
              <form action="<%=path %>/resetPasswordUserAction.action" method="post" name="passwordForm" onsubmit="return setPass();">
                <input type="hidden" name="user.userId" value="${user.userId }" />
		        <table width="100%" border="0" cellpadding="2" cellspacing="2" >
		             <tr>
					    <td height="30" align="right"><span class="f_6">新密码：</span></td>
					    <td align="left" class="f_6"><input name="user.password" style="width:150px" type="password" id="password1" /></td>
					  </tr>
					  <tr>
					    <td height="30" align="right"><span class="f_6">确认新密码：</span></td>
					    <td align="left" class="f_6"><input style="width:150px" type="password" id="password2" /></td>
					  </tr>
		            <tr class="f12"> 
		              <td height="30">&nbsp;</td>
		              <td height="30"><input type="submit" name="Submit" value="重置密码" > </td>
		            </tr>
		           </table>
		          </form>
            </c:when>
            <c:otherwise>
               	答案不匹配，请注意大小写以及空格<br><br><a href='javascript:history.go(-1)'>返回上一页</a>
            </c:otherwise>
          </c:choose>
        </td>
      </tr>      
    </table>     
  </body>
</html>
